
/****** 举借债务数据 结束 *****************/

export const Elements = [
  /** 举借债务 结束 */
  /** 举借基本情况 开始 */
  {
    id: "eFormZwjjBase",
    component: "Form",
    fields: zwjjBaseFields,
    ui: {
      change: async (
        { change, origin },
        { xe: { get, sum, pluck }, dc: { update } }
      ) => {
        const { path } = change;
        if (path.startsWith("eGridZwjjInfo")) {
          const gridData = get(origin, "eGridZwjjInfo", []);
          const BMONEY = sum(pluck(gridData, "MONEY1"));
          const PMONEY = get(origin, "eFormZwjjBase.AGREEMONEY") - BMONEY;
          update({ path: "eFormZwjjBase", value: { BMONEY, PMONEY } });
        }
      },
    },
  },


];
